import { BASE } from '../api'
import { METHOD, request } from '@/utils/request'

/* 支部相关 */
// 新增
export async function addBranch(params) {
    return request(`${BASE}/branch/save`, METHOD.POST, params)
}
// 删除
export async function delBranch(params) {
    return request(`${BASE}/branch/del`, METHOD.POST, params)
}
// 删除
export async function delBranchList(params) {
    return request(`${BASE}/branch/batchDel`, METHOD.POST, params)
}
// 修改
export async function updateBranch(params) {
    return request(`${BASE}/branch/update`, METHOD.POST, params)
}
// 分页查询
export async function getBranchList(params) {
    return request(`${BASE}/branch/page`, METHOD.POST, params)
}
// 查询全部
export async function getAllBranch(params) {
    return request(`${BASE}/branch/query`, METHOD.POST, params)
}

export default {
    addBranch,
    delBranch,
    delBranchList,
    updateBranch,
    getBranchList,
    getAllBranch
}